To create a new stock balance page a new stock balance group will need to be created and mapped to a location group, the input and output rules that generate the daily balances will need to be setup and the navigation pages to display the stock position and stock management pages will need to be created.
Stock Balance Groups need to be created for each stock group that will need to be balanced, such as Stockpile, Blasted or Drilled Stocks and mapped to the relevant location group.
To be able to create a stock balance group a Data Management Query will need to be created over the StoBalGrp table and displayed on a menu in the MiiNT interface, so that stock groups can be added.
In the above example an Inventory Management menu has been created for the purpose of managing stock balance groups and placed under the Administration menu as a Data Management View page type.
To be able to map a stock balance group to a location group a Data Management Query will need to be created over the Inventory Group Location Group table (StoBalGroLocGro) and displayed on the same menu in the MiiNT interface as the Stockpile Balance Group table, so that stock groups can be balanced.
Once the stock group has been added and mapped to a location group daily balances will be able to be created and physical balances manually entered.
Two rules need to be created to be able to balance stocks; one to generate the inputs to the stocks and another to generate the outputs from the stocks. Use Query Builder to create the XML Queries for the inputs to and outputs from the stocks.
The requirements for these rules are:
Rules | |
---|---|
Name |
The naming of the rules need to adhere to the following:
For example with the Stockpile stock group the rules would be named Stockpile_Stockpile Input and Stockpile_Stockpile Output. |
Module |
Set this field to the VolumeManagment module, as this is the module used to balance stocks. |
XML Query |
Two XML Queries need to be created to generate the daily input balance records and the daily output balance records. Use Query Builder to create these XML Queries. Refer to the XML Query Requirements table below for the required filters and output fields. |
The table below lists the required filters and output fields for the XML Query used by the Input rule.
Input Rule XML Query | Description |
---|---|
Table |
This needs to be set to the table that provides the inputs to the stocks.
|
Filters |
|
Date |
The filter must be named Date. |
Optional Filter |
An additional filter may be required to filter the input data for the stocks that require balancing. For the Drilled stock group the Drill Summary records will need to be filtered to ensures that only drilled SHOT locations will be included as inputs ie locations with a group code of SHOT. For the Blasted stock group there are no optional filter requirements on the Blast Summary records as inputs. For the Stockpiles stock group the Load & Haul records will need to be filtered to ensures that only movements TO the Stockpiles will be included as inputs ie destination locations with a group code of STOCKPILE. |
Outputs |
|
Date |
This output must be named Date. |
Source Location |
This output must be named SourceLocation. |
Destination Location |
This output must be named DestinationLocation. |
Material Code |
This output must be named Material. |
Volume |
This output must be named Volume. |
Mass |
This output must be named Mass. |
The table below lists the required filters and output fields for the XML Query used by the Output rules.
Output Rule XML Query | Description |
---|---|
Table |
This needs to be set to the table that provides the outputs to the stocks.
|
Filters |
|
Date |
The filter must be named Date. |
Optional Filter |
An additional filter may be required to filter the output data for the stocks that require balancing. For the Drilled stock group there are no optional filter requirements on the Blast Summary records as outputs. For the Blasted stock group the Load & Haul records will need to be filtered to ensures that only drilled SHOT locations will be included as outputs ie source locations with a type code in Blast..BLOCK,SHOT. For the Stockpile stock group the Load & Haul records will need to be filtered to ensures that only movements FROM the Stockpiles will be included as outputs ie source locations with a group code of STOCKPILE. |
Outputs |
|
Date |
This output must be named Date. |
Source Location |
This output must be named SourceLocation. |
Volume |
This output must be named Volume. |
Mass |
This output must be named Mass. |
Once the Stock Balance Group and the Input and Output rules have been created a new stocks balance page needs to be created to display the daily stock balances positions and management pages. Use the Administration > Navigation menu to create these pages.
The first step is to create a new page from where the stock positions can be viewed and managed.
In the example above 3 pages have been created; the Stock Positions menu that will hold the Stockpile Management and Stockpile Positions sub menus.
The below steps will be used to demonstrate how these Stock Positions pages were created.
Create a navigation page to place the stock positions and stock management pages under. Refer to the Add New Custom Menus section under the Managing Navigation Menu topic for details on how to create a new navigation menu.
Set the Category field to StockManagement.
Note: Any dashboard charts or grids that have had their Category field set to StockManagement will appear as tiles across this page.
Create a navigation page to view the stock positions. Refer to the Add New Custom Menus section under the Managing Navigation Menu topic for details on how to create a new navigation menu.
Set the StockpileBalanceGroup to the stock group code. In this example it is 1 for Stockpile.
Note: This value can be obtained by viewing the Stock Balance Group Data Management Query.
Paste the XML Query that will be used to populate the grid on the stocks position page to the GridQuery field.
Note: The query must contain Date, Location and Location Type named filters. The grid will display the output fields as they appear in the query.
The below example displays the query used to generate the grid results below.
Note: In the above query the table has been set to only return the top 20000 rows. This value may need to be changed to ensure that it captures data for the last 6 months.
Paste the XML Query that will be used to populate the chart to the ChartQuery field.
Note: The query must contain Date and GroupID named filters and Date, Location, Location Type, Material and Value (eg Volume or Mass) named outputs. The Location Type and Location named outputs generate the lookup values to filter the stock positions pages by.
The below example displays the query used to generate the chart results below.
Note: In the above query the table has been set to only return the top 20000 rows. This value may need to be changed to ensure that it captures data for the last 6 months.
Move the User Groups that will require access to this page to the Access Granted column using the Security Movement buttons. Refer to the User Module Report Security topic for information on user group security.
Note: When this menu is placed under the Stock Positions menu, it will inherit the user groups that have been granted access to that menu.
Create a navigation page for the management of stocks. Refer to the Add New Custom Menus section under the Managing Navigation Menu topic for details on how to create a new navigation menu.
Set the StockpileBalanceGroup to the stock group code. In this example it is 1 for Stockpile.
Note: This value can be obtained by viewing the Stock Balance Group Data Management Query.
Move the User Groups that will require access to this page to the Access Granted column using the Security Movement buttons. Refer to the User Module Report Security topic for information on user group security.
Note: When this menu is placed under the Stock Positions menu, it will inherit the user groups that have been granted access to that menu.